home *** CD-ROM | disk | FTP | other *** search
- Putimagefx ver 0.9 (beta)
-
- I say its a beta version because it does'nt include yet its
- "fx" counterparts, the code which makes the "fx" possible,
- thus allowing you to not only just PUT the clipping on the
- screen but to fade it in using different technices, such as
- sparkle,swipe,melt, and use palette routines to fade the
- clipping in from black or out to black or whatever color.
- The 1.0 version of Putimagefx will probably be released
- around august of '94, so look for it then.
-
- Overview:
- Putimagefx is the fastest clipping function I know of to
- date. It coppies a bitmap from memory in a specific format,
- to any segment in conventional memory. The purpose of putting
- it at any segment you choose is for maybe a hidden screen, a
- temporary page or something of that nature to aid in the
- process of flicker-free animation on IBM PC's. About a year
- ago, I started needing faster clipping functions than the
- ones supplied by Borlands BGI functions, so I went on a quest
- to find some. Oh, I found many, many that sounded REALLY
- good, Fastgraphs bitmap functions are an example. They sound
- good, and they ARE very user friendly and versitle, but the
- are horribly slow!! The overhead in making these functions
- work for so many different video modes boggs down the
- tightest assembley optimized code. So I figured since most
- decent applications these days are wrote in the MCGA mode 13h
- 320 x 200 x 256, then I would write a specific function for a
- specific video mode: mode 13h. I could go on and on about the
- +'s of mode 13h, but I wont, so don't worry. Maybe I'll write
- a book one day on it.
-
- Features:
- - Automatic transparacy of color 0
- - Automatic clipping off the right and bottom of the screen
- - FAST!!
- - Fully optimized in assembly as an .obj file.
-
- Transparancy:
- It automatically assumes color 0 is the transparancy color
- and only copies pixels other than that. 'nuff said.
-
- Clipping:
- So far clipping is only available for the right and bottom of
- the screen, this makes it ALOT faster than providing the left
- and top. Trust me, its a lot easier to code and it makes it
- alot faster, but don't worry, its commin. Also if you try to
- display the image beyond 319 or 199 it knows this and just
- returns without wasting any time doing something for nothing.
-
- Speed:
- 2500 putimagefx's per second. This is displaying a 15 x 15
- image (225 bytes) on a 386dx-40 w/ a non-accelerated video
- card. Thats more than 500k a second. This is comparable with
- Borlands BGI putimage which is about 5k per second.
-
- Assembly:
- 20 hours of hand coded assembly work and compiled as a
- linkable .obj file.
-
-
- Calling:
- Its called in my Turbo C++ 2.0 by:
- putimagefx(int x,int y,unsigned char * buffer,int
- destination)
- very easy.
- x & y are screen coordinates where the upper left corner of
- the clipping will be placed.
-
- buffer is of course the buffer in which the clipping is
- stored.
-
- destination is the segment in memory where the image is to be
- placed. An easy and quick way to display it is to put 0xa000
- as destination to copy the image directly to the VGA page
- frame.
-
- Clipping format:
- The clipping format is very simple: The first 2 bytes in the
- buffer are the width and highth respectively (yes bytes,
- the width can only be up to 256 pixels wide). The rest is
- a very primitive run length of bytes representing the pixels,
- example:
-
- byte 1 | byte 2 | byte 3 | byte 4 | and so on...
-
- byte 1 is the width of the clipping
- byte 2 is the highth of the clipping
- byte 3 is the first byte of the clipping
- byte 4 is the second byte of the clipping
-
- say you had a 2 x 2 clipping: (wow!)
-
- 2 | 2 | 8 | 5 | 5 | 7 |
-
- the display would look like this:
-
- 85 line 1 (#'s representing colors)
- 57 line 2
-
- Got it? Good. Its pretty simple.
-
-
-
- If you have any questions or comments feel free to call me at
- 867-2957 or 867-3180 or write me:
-
-
- Matthew Bradley
- 41 Oakridge rd.
- Winder, Ga. 30680
-
- Wait a minute, please write me or call or at least leave a
- message to me on my favorite BBS, the Atlanta Index, at 1-404-924-3472
- I want no $, just to know someone downloaded this file will
- be good enough for me. PLEASE!!